#include<stdio.h>
#include<stdlib.h>
#include<omp.h>

int main(int argc, char** argv) {
	int thread_count = strtol(argv[1],NULL,10);
	int tmp = 1;
#pragma omp parallel for num_threads(thread_count) private(tmp) 
	for (int i = 0; i < 10; i++)
	{
		tmp ++;
		printf("线程编号%d: 结果%d\n", omp_get_thread_num(), tmp);
	}

	printf("tmp: %d\n",tmp);

	return 0;
}
